import request from '@/utils/request'

// 查询黑名单规则配置列表
export function listBlacklistrule(query) {
  return request({
    url: '/manage/blacklistrule/list',
    method: 'get',
    params: query
  })
}

// 查询黑名单规则配置详细
export function getBlacklistrule(ruleId) {
  return request({
    url: '/manage/blacklistrule/' + ruleId,
    method: 'get'
  })
}

// 新增黑名单规则配置
export function addBlacklistrule(data) {
  return request({
    url: '/manage/blacklistrule',
    method: 'post',
    data: data
  })
}

// 修改黑名单规则配置
export function updateBlacklistrule(data) {
  return request({
    url: '/manage/blacklistrule',
    method: 'put',
    data: data
  })
}

// 删除黑名单规则配置
export function delBlacklistrule(ruleId) {
  return request({
    url: '/manage/blacklistrule/' + ruleId,
    method: 'delete'
  })
}
